<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
    <script type="text/javascript" src="/statics/js/flexible.js"></script>
    <title>修补查询</title>
    <link rel="stylesheet" href="/statics/css/bootstrap.min.css">
    <link rel="stylesheet" href="/statics/css/qxww_repair_web.css">
</head>
<body>
<div class="container">
    <!--<div class="nav text-center">
        <img src="/statics/images/wx_core_back.png" alt="">
        <div>清秀娃娃销券</div>
    </div>-->

    <div class="title clearfix">
        <div class="pull-left">销券查询</div>
        <div class="pull-left active">修补查询</div>
    </div>

    <!--修补查询  开始-->
    <form class="form-inline clearfix" id="stamp_form" action="" method="post">
        <div class="form-group pull-left">
            <input type="text" name="card_number" class="form-control" id="exampleInputName2" placeholder="请输入正确的6位券号" maxlength="6">
        </div>
        <div class="form-group pull-left">
            <input type="text" name="user_content" class="form-control" id="exampleInputEmail2" placeholder="请输入姓名或手机号" maxlength="11">
        </div>
        <button type="button" class="pull-right" id="search_btn">查询</button>
    </form>
    <!--修补查询  结束-->

    <!--输入错误  开始-->
    <div style="color: #FF0000;font-size: 0.32rem;margin-top: 2px;display: none;" id="error_tip">输入错误</div>
    <!--输入错误  结束-->

    <!--查询成功  本人修补、他人修补  开始-->
    <div id="search_unstamp">
        <table class="table">
            <tbody>
            <tr>
                <td>券号</td>
                <td>QX00000001</td>
            </tr>
            <tr>
                <td>姓名</td>
                <td>清秀</td>
            </tr>
            <tr>
                <td>操作项目</td>
                <td>面部</td>
            </tr>
            <tr>
                <td>消费时间</td>
                <td>2017-10-31</td>
            </tr>
            <tr>
                <td>修补机会</td>
                <td style="color: #0FC799;">有</td>
            </tr>
            </tbody>
        </table>
        <div class="clearfix">
            <div class="pull-right" id="self_repair">本人修补</div>
            <div class="pull-right" id="other_repair">他人修补</div>
        </div>
    </div>
    <!--查询成功  本人修补、他人修补  结束-->

    <!--查询失败  无此券  开始-->
    <div id="unsearch_nostamp">
        <table class="table">
            <thead>
            <tr>
                <td>券号</td>
                <td>防伪码</td>
                <td>是否已销券</td>
            </tr>
            </thead>
            <tbody>
            <tr>
                <td>QX00000001</td>
                <td>QX00000001</td>
                <td style="color: #0FC799;">无此券</td>
            </tr>
            </tbody>
        </table>
    </div>
    <!--查询失败  无此券  结束-->

    <!--查询成功  已修补  开始-->
    <div id="search_stampend">
        <table class="table">
            <tbody>
            <tr>
                <td>券号</td>
                <td>QX00000001</td>
            </tr>
            <tr>
                <td>姓名</td>
                <td>清秀</td>
            </tr>
            <tr>
                <td>操作项目</td>
                <td>面部</td>
            </tr>
            <tr>
                <td>消费时间</td>
                <td>2017-10-31</td>
            </tr>
            <tr>
                <td>修补机会</td>
                <td style="color: #0FC799;">已修补</td>
            </tr>
            </tbody>
        </table>
    </div>
    <!--查询成功  已修补  结束-->

    <!--历史记录  开始-->
    <div class="history">
        <div class="history_title">历史记录</div>
        <div class="history_table">
            <table class="table">
                <thead>
                <tr>
                    <td>券号</td>
                    <td>操作员</td>
                    <td>次数</td>
                </tr>
                </thead>
                <tbody>
                <?php if($history){ foreach($history as $val){ ?>
                <tr>
                    <td><?=$val['card_number']?></td>
                    <td><?=$operator?>/<?=$val['type']==1?'查询':($val['type']==2?'修补':无)?></td>
                    <td><?=$val['times']?></td>
                </tr>
                <?php }}else{?>
                <tr>
                    <td colspan="3">暂无数据</td>
                </tr>
                <?php }?>
                </tbody>
            </table>
        </div>
    </div>
    <!--历史记录  结束-->

    <div class="clearfix">
        <div class="pull-left">
            <a href="/user/loginout"><div id="out_login">退出</div></a>
        </div>
        <div class="pull-left">
            <div id="fix_password">修改密码</div>
        </div>
    </div>
</div>

<!--本人修补弹层  开始-->
<div class="modal fade" tabindex="-1" role="dialog" id="stamp_modal">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <div class="close" data-dismiss="modal" aria-label="Close">
                    <img style="vertical-align: 2px;" src="/statics/images/sever_close.png" alt="">
                </div>
                <h4 class="modal-title">本人修补</h4>
            </div>
            <div class="modal-body">
                <div>是否确认修补?</div>
                <form action="/index/self_xiubu" method="post" id="stamp_modal_" style="display: none;">
                    <input type="text" name="card_number"><!--券号-->
                    <input type="text" name="user_name"><!--姓名-->
                </form>
            </div>
            <div class="modal-footer clearfix">
                <div class="pull-left" data-dismiss="modal">取消</div>
                <div class="pull-left" id="modal_sure">确定</div>
            </div>
        </div>
    </div>
</div>
<!--本人修补弹层  结束-->

<!--他人修补弹层  开始-->
<div class="modal fade" tabindex="-1" role="dialog" id="stamp_modal_other">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <div class="close" data-dismiss="modal" aria-label="Close">
                    <img style="vertical-align: 2px;" src="/statics/images/sever_close.png" alt="">
                </div>
                <h4 class="modal-title">他人修补</h4>
            </div>
            <div class="modal-body">
                <form class="" action="/index/another_xiubu" id="stamp_modal_form" method="post">
                    <div class="clearfix">
                        <div class="pull-left">顾客姓名</div>
                        <div class="pull-left"><input name="xiubu_uname" type="text" placeholder="输入顾客姓名"></div>
                    </div>
                    <div class="clearfix">
                        <div class="pull-left">手机号</div>
                        <div class="pull-left"><input name="xiubu_mobile" type="text" placeholder="输入顾客手机号" maxlength="11"></div>
                    </div>
                    <div class="clearfix">
                        <div class="pull-left">修补项目</div>
                        <div class="pull-left" id="select_repair_project">
                            <input id="select_repair_project_input" onfocus="this.blur()" name="xiubu_project" type="text" placeholder="选择修补项目">
                            <img src="/statics/images/sever_unretrieve.png" alt="">
                            <div id="select_repair_project_select">
                                <?php if($projects){ foreach($projects as $v){?>
                                <div class="clearfix">
                                    <div class="pull-left"><?=$v?></div>
                                    <div class="pull-right"><img src="/statics/images/write_img.jpg" alt=""></div>
                                </div>
                                <?php }}?>
                            </div>
                        </div>
                    </div>

                    <input type="text" name="card_number" style="display: none"><!--券号-->
                    <input type="text" name="user_name" style="display: none"><!--姓名-->
                </form>
            </div>
            <div class="modal-footer clearfix">
                <div class="pull-left" data-dismiss="modal">取消</div>
                <div class="pull-left" id="modal_sure_other">确定</div>
            </div>
        </div>
    </div>
</div>
<!--他人修补弹层  结束-->

<!--修改密码  开始-->
<div class="modal fade" tabindex="-1" role="dialog" id="stamp_password_modal">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <div class="close" data-dismiss="modal" aria-label="Close">
                    <img style="vertical-align: 2px;" src="/statics/images/sever_close.png" alt="">
                </div>
                <h4 class="modal-title">修改密码</h4>
            </div>
            <div class="modal-body">
                <form action="/user/userUpdate" id="stamp_password_form" method="post">
                    <div class="clearfix">
                        <div class="pull-left">密码</div>
                        <div class="pull-left"><input name="password" type="password" placeholder="输入密码"></div>
                    </div>
                    <div class="clearfix">
                        <div class="pull-left">确认密码</div>
                        <div class="pull-left"><input name="new_password" type="password" placeholder="请确认密码"></div>
                    </div>
                    <div style="color: #FF0000;display: none;" id="password_tip">两次密码输入不正确</div>
                </form>
            </div>
            <div class="modal-footer clearfix">
                <div class="pull-left" data-dismiss="modal">取消</div>
                <div class="pull-left" id="modal_password_sure">确定</div>
            </div>
        </div>
    </div>
</div>
<!--修改密码  结束-->

<!--信息提示  开始-->
<div class="modal fade" tabindex="-1" role="dialog" id="login_modal">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <div class="close" data-dismiss="modal" aria-label="Close">
                    <img src="/statics/images/sever_close.png" alt="">
                </div>
                <h4 class="modal-title">销券提示</h4>
            </div>
            <div class="modal-body">
                <div id="modal_error">是否确认修补?</div>
            </div>
            <div class="modal-footer clearfix">
                <div class="pull-left" data-dismiss="modal">确定</div>
            </div>
        </div>
    </div>
</div>
<!--信息提示  结束-->

<script src="/statics/js/jquery-3.2.1.js"></script>
<script src="/statics/js/bootstrap.min.js"></script>
<script src="/statics/js/qxww_repair_web.js"></script>
</body>
</html>